/*****************************************************************************
*
*  PROJECT:		
*               
*  LICENSE:		
*
*  DEVELOPER:	
*
*****************************************************************************/

#ifndef EONSKYBOX_H
#define EONSKYBOX_H

#include <Windows.h>

#include "EonCamera.h"

#include <gl\glut.h>

// OpenGL cube mapping defines
#define GL_NORMAL_MAP_EXT                   0x8511
#define GL_REFLECTION_MAP_EXT               0x8512
#define GL_TEXTURE_CUBE_MAP_EXT             0x8513
#define GL_TEXTURE_BINDING_CUBE_MAP_EXT     0x8514
#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT  0x8515
#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT  0x8516
#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT  0x8517
#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT  0x8518
#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT  0x8519
#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT  0x851A
#define GL_PROXY_TEXTURE_CUBE_MAP_EXT       0x851B
#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT    0x851C
#define GL_CLAMP_TO_EDGE					0x812F
#define GL_TEXTURE_WRAP_R					0x8072

// CSkybox defines
#define TEX_COORD							1.0f
#define SKY_DISTANCE						50.0f

namespace Eon
{
	class Skybox
	{
		public:

			void render( Eon::Camera camera );
			int init();
			GLuint getCubeMapTexture( void );

		private:

			bool loadFace( GLenum target, char *filename );
			GLuint cubeMap;
	};
}

#endif // CSKYBOX_H